﻿<%@ Page Language="C#" MasterPageFile="~/Admin/Admin.master" AutoEventWireup="true" CodeBehind="SendGoodsManage.aspx.cs" Inherits="XinBang.Web.Admin.SendGoodsManage" Title="无标题页" %>
<asp:Content ID="Content1" ContentPlaceHolderID="headerplace" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="mainplace" runat="server">
<h2><asp:Literal ID="ttitle" runat="server" Text="发货管理"></asp:Literal></h2>
<asp:MultiView ID="MultiView1" runat="server">
    <asp:View ID="View1" runat="server">
        <ul>
            <li><a href="SendGoodsManage.aspx?action=sendlist">查看需要发货的订单列表</a></li>
        </ul>
    </asp:View>
    <asp:View ID="View2" runat="server">
        <asp:GridView ID="GridView1" runat="server" AllowPaging="True" AutoGenerateColumns="False"
            CssClass="show" PageSize="20" DataKeyNames="Ordid" OnSelectedIndexChanged="BindOrderRecord">
            <Columns>
                <asp:BoundField DataField="Ordid" HeaderText="订单编号" SortExpression="Ordid" >
                    <ItemStyle HorizontalAlign="Center" />
                </asp:BoundField>
                <asp:BoundField DataField="Memid" HeaderText="订货人" ReadOnly="True" SortExpression="Memid" >
                    <ItemStyle HorizontalAlign="Center" />
                </asp:BoundField>
                <asp:BoundField DataField="OrderTime" HeaderText="订货时间" ReadOnly="True"  SortExpression="OrderTime" >
                    <ItemStyle HorizontalAlign="Center" />
                </asp:BoundField>
                <asp:BoundField DataField="OrderValue" HeaderText="订单价格" ReadOnly="True"  SortExpression="OrderValue" >
                    <ItemStyle HorizontalAlign="Center" />
                </asp:BoundField>
                <asp:BoundField DataField="Senid" HeaderText="发货方式" ReadOnly="True"  SortExpression="Senid" >
                    <ItemStyle HorizontalAlign="Center" />
                </asp:BoundField>
                <asp:BoundField DataField="SendTime" HeaderText="发货时间" ReadOnly="True"  SortExpression="SendTime" NullDisplayText="未发货" >
                    <ItemStyle HorizontalAlign="Center" />
                </asp:BoundField>
                <asp:BoundField DataField="PayValue" HeaderText="应付价格" ReadOnly="True"  SortExpression="PayValue">
                    <ItemStyle HorizontalAlign="Center" />
                </asp:BoundField>
                <asp:BoundField DataField="PayTime" HeaderText="付款时间" ReadOnly="True"  SortExpression="PayTime" NullDisplayText="未付款"  >
                    <ItemStyle HorizontalAlign="Center" />
                </asp:BoundField>
                <asp:BoundField DataField="ReceiveTime" HeaderText="收货时间" ReadOnly="True"  SortExpression="ReceiveTime" NullDisplayText="未到货" >
                    <ItemStyle HorizontalAlign="Center" />
                </asp:BoundField>
                <asp:CommandField HeaderText="处理订单" SelectText="处理" ShowSelectButton="True">
                    <ItemStyle HorizontalAlign="Center" />
                </asp:CommandField>
            </Columns>
            <AlternatingRowStyle CssClass="alt" />
            <PagerStyle CssClass="pager" />
            <PagerSettings FirstPageText="首页" LastPageText="末页" Mode="NextPreviousFirstLast"
                    NextPageText="下一页" PreviousPageText="上一页" />
            <EmptyDataTemplate>
                没有查询到的订单。
            </EmptyDataTemplate>
        </asp:GridView>
        <asp:Panel ID="recordPanel" runat="server" Visible="false">
            <div class="show">
                订单编号:<asp:Label ID="labelOrderId" runat="server" Text="Label"></asp:Label> &nbsp;
                订货人:<asp:Label ID="labelGuestName" runat="server" Text="Label"></asp:Label>&nbsp;
                订货时间:<asp:Label ID="labelOrderTime" runat="server" Text="Label"></asp:Label>
                联系电话:<asp:Label ID="labelPhone" runat="server" Text="Label"></asp:Label><br />
                联系地址:<asp:Label ID="labelAddress" runat="server" Text="Label"></asp:Label><br />
                订单状态:<asp:Label ID="labelPay" runat="server" Text="Label"></asp:Label> 
                <asp:Label ID="labelSend" runat="server" Text="Label"></asp:Label> 
                <asp:Label ID="labelReceive" runat="server" Text="Label"></asp:Label>
            </div>
            
            <asp:GridView ID="recordGridView" CssClass="show" runat="server" AutoGenerateColumns="false">
                <Columns>
                    <asp:BoundField DataField="Recid" HeaderText="记录编号" SortExpression="Recid" >
                        <ItemStyle HorizontalAlign="Center" />
                    </asp:BoundField>
                    <asp:BoundField DataField="Gooid" HeaderText="商品名称" ReadOnly="True" SortExpression="Gooid" >
                    </asp:BoundField>
                    <asp:BoundField DataField="Amount" HeaderText="数量" ReadOnly="True"  SortExpression="Amount" >
                        <ItemStyle HorizontalAlign="Center" />
                    </asp:BoundField>
                    <asp:BoundField DataField="GoodsPrice" HeaderText="销售价格" ReadOnly="True"  SortExpression="GoodsPrice" >
                        <ItemStyle HorizontalAlign="Center" />
                    </asp:BoundField>
                </Columns>
                <AlternatingRowStyle CssClass="alt"  />
            </asp:GridView>
            <div class="show">
                订单操作:<asp:LinkButton ID="linkSend" runat="server" OnClick="linkSend_Click" Enabled="False">库房确认已发货</asp:LinkButton>
            </div>
        </asp:Panel>
    </asp:View>
</asp:MultiView>
</asp:Content>